using Google.ProtocolBuffers;
using micromsg.Proto;
using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Runtime.CompilerServices;
namespace micromsg
{
	[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
	public sealed class ModUserDomainEmail : GeneratedMessageLite<ModUserDomainEmail, ModUserDomainEmail.Builder>
	{
		[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
		public sealed class Builder : GeneratedBuilderLite<ModUserDomainEmail, ModUserDomainEmail.Builder>
		{
			private bool resultIsReadOnly;
			private ModUserDomainEmail result;
			protected override ModUserDomainEmail.Builder ThisBuilder
			{
				get
				{
					return this;
				}
			}
			public override bool IsInitialized
			{
				get
				{
					return this.result.IsInitialized;
				}
			}
			protected override ModUserDomainEmail MessageBeingBuilt
			{
				get
				{
					return this.PrepareBuilder();
				}
			}
			public override ModUserDomainEmail DefaultInstanceForType
			{
				get
				{
					return ModUserDomainEmail.DefaultInstance;
				}
			}
			public uint Status
			{
				get
				{
					return this.result.Status;
				}
				set
				{
					this.SetStatus(value);
				}
			}
			public SKBuiltinString_t Email
			{
				get
				{
					return this.result.Email;
				}
				set
				{
					this.SetEmail(value);
				}
			}
			public Builder()
			{
				this.result = ModUserDomainEmail.DefaultInstance;
				this.resultIsReadOnly = true;
			}
			internal Builder(ModUserDomainEmail cloneFrom)
			{
				this.result = cloneFrom;
				this.resultIsReadOnly = true;
			}
			private ModUserDomainEmail PrepareBuilder()
			{
				if (this.resultIsReadOnly)
				{
					ModUserDomainEmail other = this.result;
					this.result = new ModUserDomainEmail();
					this.resultIsReadOnly = false;
					this.MergeFrom(other);
				}
				return this.result;
			}
			public override ModUserDomainEmail.Builder Clear()
			{
				this.result = ModUserDomainEmail.DefaultInstance;
				this.resultIsReadOnly = true;
				return this;
			}
			public override ModUserDomainEmail.Builder Clone()
			{
				if (this.resultIsReadOnly)
				{
					return new ModUserDomainEmail.Builder(this.result);
				}
				return new ModUserDomainEmail.Builder().MergeFrom(this.result);
			}
			public override ModUserDomainEmail BuildPartial()
			{
				if (this.resultIsReadOnly)
				{
					return this.result;
				}
				this.resultIsReadOnly = true;
				return this.result.MakeReadOnly();
			}
			public override ModUserDomainEmail.Builder MergeFrom(IMessageLite other)
			{
				if (other is ModUserDomainEmail)
				{
					return this.MergeFrom((ModUserDomainEmail)other);
				}
				base.MergeFrom(other);
				return this;
			}
			public override ModUserDomainEmail.Builder MergeFrom(ModUserDomainEmail other)
			{
				return this;
			}
			public override ModUserDomainEmail.Builder MergeFrom(ICodedInputStream input)
			{
				return this.MergeFrom(input, ExtensionRegistry.Empty);
			}
			public override ModUserDomainEmail.Builder MergeFrom(ICodedInputStream input, ExtensionRegistry extensionRegistry)
			{
				this.PrepareBuilder();
				uint num;
				string text;
				while (input.ReadTag(out num, out text))
				{
					if (num == 0u && text != null)
					{
						int num2 = Array.BinarySearch<string>(ModUserDomainEmail._modUserDomainEmailFieldNames, text, StringComparer.get_Ordinal());
						if (num2 < 0)
						{
							this.ParseUnknownField(input, extensionRegistry, num, text);
							continue;
						}
						num = ModUserDomainEmail._modUserDomainEmailFieldTags[num2];
					}
					uint num3 = num;
					if (num3 == 0u)
					{
						throw InvalidProtocolBufferException.InvalidTag();
					}
					if (num3 != 8u)
					{
						if (num3 != 18u)
						{
							if (WireFormat.IsEndGroupTag(num))
							{
								return this;
							}
							this.ParseUnknownField(input, extensionRegistry, num, text);
						}
						else
						{
							SKBuiltinString_t.Builder builder = SKBuiltinString_t.CreateBuilder();
							if (this.result.hasEmail)
							{
								builder.MergeFrom(this.Email);
							}
							input.ReadMessage(builder, extensionRegistry);
							this.Email = builder.BuildPartial();
						}
					}
					else
					{
						this.result.hasStatus = input.ReadUInt32(ref this.result.status_);
					}
				}
				return this;
			}
			public ModUserDomainEmail.Builder SetStatus(uint value)
			{
				this.PrepareBuilder();
				this.result.hasStatus = true;
				this.result.status_ = value;
				return this;
			}
			public ModUserDomainEmail.Builder ClearStatus()
			{
				this.PrepareBuilder();
				this.result.hasStatus = false;
				this.result.status_ = 0u;
				return this;
			}
			public ModUserDomainEmail.Builder SetEmail(SKBuiltinString_t value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasEmail = true;
				this.result.email_ = value;
				return this;
			}
			public ModUserDomainEmail.Builder SetEmail(SKBuiltinString_t.Builder builderForValue)
			{
				ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
				this.PrepareBuilder();
				this.result.hasEmail = true;
				this.result.email_ = builderForValue.Build();
				return this;
			}
			public ModUserDomainEmail.Builder MergeEmail(SKBuiltinString_t value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				if (this.result.hasEmail && this.result.email_ != SKBuiltinString_t.DefaultInstance)
				{
					this.result.email_ = SKBuiltinString_t.CreateBuilder(this.result.email_).MergeFrom(value).BuildPartial();
				}
				else
				{
					this.result.email_ = value;
				}
				this.result.hasEmail = true;
				return this;
			}
			public ModUserDomainEmail.Builder ClearEmail()
			{
				this.PrepareBuilder();
				this.result.hasEmail = false;
				this.result.email_ = null;
				return this;
			}
		}
		public const int StatusFieldNumber = 1;
		public const int EmailFieldNumber = 2;
		private static readonly ModUserDomainEmail defaultInstance;
		private static readonly string[] _modUserDomainEmailFieldNames;
		private static readonly uint[] _modUserDomainEmailFieldTags;
		private bool hasStatus;
		private uint status_;
		private bool hasEmail;
		private SKBuiltinString_t email_;
		private int memoizedSerializedSize = -1;
		public static ModUserDomainEmail DefaultInstance
		{
			get
			{
				return ModUserDomainEmail.defaultInstance;
			}
		}
		public override ModUserDomainEmail DefaultInstanceForType
		{
			get
			{
				return ModUserDomainEmail.DefaultInstance;
			}
		}
		protected override ModUserDomainEmail ThisMessage
		{
			get
			{
				return this;
			}
		}
		public uint Status
		{
			get
			{
				return this.status_;
			}
		}
		public SKBuiltinString_t Email
		{
			get
			{
				return this.email_ ?? SKBuiltinString_t.DefaultInstance;
			}
		}
		public override bool IsInitialized
		{
			get
			{
				return this.hasStatus && this.hasEmail;
			}
		}
		public override int SerializedSize
		{
			get
			{
				int num = this.memoizedSerializedSize;
				if (num != -1)
				{
					return num;
				}
				num = 0;
				if (this.hasStatus)
				{
					num += CodedOutputStream.ComputeUInt32Size(1, this.Status);
				}
				if (this.hasEmail)
				{
					num += CodedOutputStream.ComputeMessageSize(2, this.Email);
				}
				this.memoizedSerializedSize = num;
				return num;
			}
		}
		private ModUserDomainEmail()
		{
		}
		public override void WriteTo(ICodedOutputStream output)
		{
			int arg_06_0 = this.SerializedSize;
			string[] modUserDomainEmailFieldNames = ModUserDomainEmail._modUserDomainEmailFieldNames;
			if (this.hasStatus)
			{
				output.WriteUInt32(1, modUserDomainEmailFieldNames[1], this.Status);
			}
			if (this.hasEmail)
			{
				output.WriteMessage(2, modUserDomainEmailFieldNames[0], this.Email);
			}
		}
		public override int GetHashCode()
		{
			int num = base.GetType().GetHashCode();
			if (this.hasStatus)
			{
				num ^= this.status_.GetHashCode();
			}
			if (this.hasEmail)
			{
				num ^= this.email_.GetHashCode();
			}
			return num;
		}
		public override bool Equals(object value)
		{
			ModUserDomainEmail modUserDomainEmail = value as ModUserDomainEmail;
			return modUserDomainEmail != null && (this.hasStatus == modUserDomainEmail.hasStatus && (!this.hasStatus || this.status_.Equals(modUserDomainEmail.status_))) && (this.hasEmail == modUserDomainEmail.hasEmail && (!this.hasEmail || this.email_.Equals(modUserDomainEmail.email_)));
		}
		public override void PrintTo(TextWriter writer)
		{
			GeneratedMessageLite<ModUserDomainEmail, ModUserDomainEmail.Builder>.PrintField("Status", this.hasStatus, this.status_, writer);
			GeneratedMessageLite<ModUserDomainEmail, ModUserDomainEmail.Builder>.PrintField("Email", this.hasEmail, this.email_, writer);
		}
		public static ModUserDomainEmail ParseFrom(byte[] data)
		{
			return ModUserDomainEmail.CreateBuilder().MergeFrom(data).BuildParsed();
		}
		private ModUserDomainEmail MakeReadOnly()
		{
			return this;
		}
		public static ModUserDomainEmail.Builder CreateBuilder()
		{
			return new ModUserDomainEmail.Builder();
		}
		public override ModUserDomainEmail.Builder ToBuilder()
		{
			return ModUserDomainEmail.CreateBuilder(this);
		}
		public override ModUserDomainEmail.Builder CreateBuilderForType()
		{
			return new ModUserDomainEmail.Builder();
		}
		public static ModUserDomainEmail.Builder CreateBuilder(ModUserDomainEmail prototype)
		{
			return new ModUserDomainEmail.Builder(prototype);
		}
		static ModUserDomainEmail()
		{
			ModUserDomainEmail.defaultInstance = new ModUserDomainEmail().MakeReadOnly();
			ModUserDomainEmail._modUserDomainEmailFieldNames = new string[]
			{
				"Email",
				"Status"
			};
			ModUserDomainEmail._modUserDomainEmailFieldTags = new uint[]
			{
				18u,
				8u
			};
			object.ReferenceEquals(micromsg.Proto.ModUserDomainEmail.Descriptor, null);
		}
	}
}
